# # while循环
# # i = 1
# # sum = 0
# # while i <=100 :
# #     sum += i
# #     i += 1
# # print(f"1到100的和是{sum}")
# # 猜数字游戏
# # import random
# #
# # num = random.randint(1, 100)
# # count = 0
# # flag = True
# # while flag:
# #     gess_num = int(input("请猜数字"))
# #     count += 1
# #     if gess_num == num:
# #         print("恭喜你猜对了")
# #         flag = False
# #     else:
# #         if gess_num > num:
# #             print("猜大了")
# #         else:
# #             print("猜小了")
# # print(f"一共猜了{count}次")
#
# # while 实现九九乘法表
# # i = 1
# # while i <= 9:
# #     j = 1
# #     while j <= i:
# #         print(f"{j}*{i}={j * i}\t", end='')
# #         j += 1
# #     i += 1
# #     print()
#
# # for循环基本操作
# # 找a
# # name ="feawafafeaea"
# # count =0
# # for x in name:
# #     if x=="a":
# #
# #         count +=1
# # print(count)
#
# # range 函数
# # for x in range(5):
# #     print(x, end='')
# #
# # for x in range(3, 6):  # 都不包括最后一个树
# #
# #     print(x, end='')
# #
# # for x in range(3, 10, 2):
# #     print(x, end='')
#
# # for循环实现九九乘法表
# for x in range(1, 10):
#     for j in range(1, x + 1):
#         print(f"{j}*{x}={j * x}\t", end='')
#     print()
